import 'dart:convert';

class LanguageInfo {
  final String languageCode;
  final String countryCode;

  LanguageInfo({required this.languageCode, required this.countryCode});

  factory LanguageInfo.fromJson(Map<String, dynamic> json) {
    return LanguageInfo(
      languageCode: json['languageCode'] ?? '',
      countryCode: json['countryCode'] ?? '',
    );
  }

  Map<String, dynamic> toJson() {
    final Map<String, dynamic> data = <String, dynamic>{};
    data['languageCode'] = languageCode;
    data['countryCode'] = countryCode;
    return data;
  }

  @override
  String toString() {
    return jsonEncode(toJson());
  }
}
